

        <g:set var="entityName" value="${message(code: 'post.label', default: 'Post')}" />
            <div class="list">
                <table>
                    <thead>
                        <tr>
                        
                            <g:sortableColumn property="title" title="${message(code: 'post.title.label', default: 'Title')}" />
                        
                            <g:sortableColumn property="content" title="${message(code: 'post.content.label', default: 'Content')}" />
                        
                            <th><g:message code="post.student.label" default="Student" /></th>
                   	    
                            <th><g:message code="post.teacher.label" default="Teacher" /></th>
                   	    
                            <g:sortableColumn property="createTime" title="${message(code: 'post.createTime.label', default: 'Create Time')}" />
                        
                        </tr>
                    </thead>
                    <tbody>
                    <g:each in="${postInstanceList}" status="i" var="postInstance">
                        <tr class="${(i % 2) == 0 ? 'odd' : 'even'}">
                        
                            <td><g:link action="show" id="${postInstance.id}">${fieldValue(bean: postInstance, field: "title")}</g:link></td>
                        
                            <td>${fieldValue(bean: postInstance, field: "content")}</td>
                        
                            <td>${fieldValue(bean: postInstance, field: "student")}</td>
                        
                            <td>${fieldValue(bean: postInstance, field: "teacher")}</td>
                        
                            <td><g:formatDate date="${postInstance.createTime}" /></td>
                        
                        </tr>
                    </g:each>
                    </tbody>
                </table>
            </div>
            <div class="paginateButtons">
                <x:paginate total="${postInstanceTotal}" />
            </div>
